package com.xiaochong.tir.common.data.mapper;

import com.xiaochong.tir.common.data.mapper.base.BaseDao;
import com.xiaochong.tir.common.data.po.ConceptCategory;
import com.xiaochong.tir.common.data.po.CurrencyIndustryCategory;
import com.xiaochong.tir.common.data.po.CurrencyInfo;
import com.xiaochong.tir.common.data.vo.*;
import org.springframework.data.repository.query.Param;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * 此类为[基础代码]自动生成，继承了BaseDao类，已经拥有基本的增删改成操作
 * <其他请自行扩展>
 *
 * @author cx
 * @time 2018-04-26 16:01
 */
public interface CurrencyInfoMapper extends BaseDao<CurrencyInfo, Integer> {

    //货币列表
    List<CurrencyList> serchByEntity(CurrencyList currencyList);

    List<CurrencyList> SerchConcept(@Param("id") Integer id);

    List<CurrencyInfo> selectAllEnableCurrencyList();

    List<CurrencyInfo> serchByCurrentId(CurrencyInfo currencyInfo);

    List<CurrencyInfo> serchByCurrenByIncurrId(CurrencyInfo currencyInfo);

    /**
     * 获取所有启用的货币
     *
     * @return
     */
    List<ApiAllEnableCurrencyInfoVo> getAllEnableCurrencyInfoList();

    List<CurrencyInfo> selectNotNullFixedTurnoverRate();


    List<CurrencyInfo> getCurrencyList(CurrencyInfo currencyInfo);

    /**
     * 获取所有货币cmcId
     *
     * @return List
     */
    List<String> getAllEnableCurrencyInfoCmcList();

    List<CurrencyIndustryCategory> industryList();

    List<ConceptCategory> conceptCategoryList();

	List<CurrencyInfo> listCurrency(CurrencyInfo currencyInfo);

    List<CurrencyInfo> getUniqueness(CurrencyInfo currencyInfo);

    List<CurrencyTraVo> selectCurrencyTraList(@Param("currencyId") Integer currencyId);

    int updateCurrencyTra(@Param("currencyId") Integer currencyId);

    List<CurrencyTraVo> selExchangeTraList(CurrencyTraVo cv);

    List<CurrencyExchangeTransaction> getCurrencyExchangeTransaction();


    /**
     * 获取货币详细信息
     * @param cmcId
     * @return
     */
    Map<String, Object> getCurrencyInfoDetail(String cmcId);

    List<CurrencyInfoApiPo> addSelfSelectCurrencySea(Map<String, Object> params);

    List<CurrencyTraVo> selCurTraList(@Param("id") Integer id);

    <T> List<T> selAppExTra(CurrencyTraVo cv);

    List<BasePeriodHistoryVo> selectByHistoryList();

    CurrencyInfo selectByEntityOwn(CurrencyInfo currencyInfo);
}